package com.icart.entities;

import javax.persistence.*;

@Entity
@Table(name = "cu_custtcmeteitem", schema = "amp", catalog = "")
@IdClass(CuCusttcmeteitemEntityPK.class)
public class CuCusttcmeteitemEntity {
    private long tcoid;
    private long custid;
    private long tcid;
    private long metaitemid;
    private Integer mcount;

    @Id
    @Column(name = "tcoid")
    public long getTcoid() {
        return tcoid;
    }

    public void setTcoid(long tcoid) {
        this.tcoid = tcoid;
    }

    @Basic
    @Column(name = "custid")
    public long getCustid() {
        return custid;
    }

    public void setCustid(long custid) {
        this.custid = custid;
    }

    @Basic
    @Column(name = "tcid")
    public long getTcid() {
        return tcid;
    }

    public void setTcid(long tcid) {
        this.tcid = tcid;
    }

    @Id
    @Column(name = "metaitemid")
    public long getMetaitemid() {
        return metaitemid;
    }

    public void setMetaitemid(long metaitemid) {
        this.metaitemid = metaitemid;
    }

    @Basic
    @Column(name = "mcount")
    public Integer getMcount() {
        return mcount;
    }

    public void setMcount(Integer mcount) {
        this.mcount = mcount;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        CuCusttcmeteitemEntity that = (CuCusttcmeteitemEntity) o;

        if (tcoid != that.tcoid) return false;
        if (custid != that.custid) return false;
        if (tcid != that.tcid) return false;
        if (metaitemid != that.metaitemid) return false;
        if (mcount != null ? !mcount.equals(that.mcount) : that.mcount != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = (int) (tcoid ^ (tcoid >>> 32));
        result = 31 * result + (int) (custid ^ (custid >>> 32));
        result = 31 * result + (int) (tcid ^ (tcid >>> 32));
        result = 31 * result + (int) (metaitemid ^ (metaitemid >>> 32));
        result = 31 * result + (mcount != null ? mcount.hashCode() : 0);
        return result;
    }
}
